package com.zhuhjay.service.system.event;

import lombok.Getter;
import org.springframework.context.ApplicationEvent;

/**
 * 用户下线事件
 *
 * @author ZhuHJay
 * @date 2023/7/12 10:27
 */
@Getter
public class UserOfflineEvent extends ApplicationEvent {
    private final String username;
    /**
     * 若指定则删除单个连接, 不指定则删除所有连接
     */
    private final String uid;

    public UserOfflineEvent(Object source, String username, String uid) {
        super(source);
        this.username = username;
        this.uid = uid;
    }
}
